package com.brook.controller;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author Brook
 */
@RestController
public class HelloController {

    Logger logger = LoggerFactory.getLogger(HelloController.class);

    @RequestMapping("/hello")
    //@PreAuthorize("hasAuthority('system:test:list')")
    @PreAuthorize("@ex.hasAuthority('system:test:list')")
    public String hello() {

        logger.info("12222222222222222222");
        return "resdsd";
    }
}
